﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Hematology.Tools;

namespace Hematology.UserSite.controls
{
    public partial class AlphabetList : System.Web.UI.UserControl
    {
        public EnumHelper.GeographicPoint TargetPoint
        {
            get
            {
                return ViewState["CurrentGeographicPoint"] != null
                           ? (EnumHelper.GeographicPoint)Enum.Parse(typeof(EnumHelper.GeographicPoint), ViewState["CurrentGeographicPoint"].ToString())
                           : EnumHelper.GeographicPoint.Countries;
            }
            set { ViewState["CurrentGeographicPoint"] = value; }
        }

        private void FillLetterList()
        {
            string[] cLetterList = new string[] { "А", "Б", "В", "Г", "Д", "Е", "Ж", "З", "И", "Й", "К", "Л", "М", "Н", "О", "П", "Р", "С", "Т", "У", "Ф", "Х", "Ц", "Ч", "Ш", "Щ", "Э", "Ю", "Я" };

            rptAlphabetLinks.DataSource = cLetterList;
            rptAlphabetLinks.DataBind();
        }

        protected void Page_Load(object sender, EventArgs e)
        {
            FillLetterList();
        }
    }
}